package shili.service.impl;


import org.aopalliance.intercept.Joinpoint;

import java.util.Arrays;
import java.util.logging.Logger;

/**
 * UserServiceLogger
 *
 * @author boy
 * @since 2023/10/13
 */
public class UserServiceLogger {
    private static final Logger log=Logger.getLogger(String.valueOf(UserServiceLogger.class));
    public void before(Joinpoint jp){
        log.info("调用"+jp.getTarget()+"的"+jp.getSignature().getName()+"方法，方法入参"+ Arrays.toString(jp.getArgs()) +"");
    }
    public void afterReturning(Joinpoint jp,Object result){
        log.info("调用"+jp.getTarget()+"的"+jp.getSignature().getName()+"方法，返回参数"+result);
    }
}
